﻿using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace jindong
{
    public class User:User_profile
    {
        /// <summary>
        /// ⽤户ID
        /// </summary>
        [Key]
        [Required]
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
        public Guid User_id { get; set; }

        [Column]
        /// <summary>
        /// ⼿机号
        /// </summary>
        [StringLength(11)]
        [Required]
        public string? mobile { get; set; }

        [Required]
        [StringLength(128)]
        /// <summary>
        /// 加密后的密码
        /// </summary>
        public int password_hash { get; set; }

        [Column]
        /// <summary>
        /// ⽤户昵称
        /// </summary>
        [StringLength(64)]
        public string? nickname { get; set; }

        [Column]
        /// <summary>
        /// 最后登录时间
        /// </summary>
        public DateTime last_login { get; set; }
    }
}
